package com.googlecode.monitoring.ws.model;

/**
 * Author: Sergiy Doroshenko
 * Date: Jun 15, 2010
 * Time: 1:36:08 PM
 */
public class CfpSecurity {
	private String login;
	private String password;

	public CfpSecurity() {
		super();
	}

	public CfpSecurity(String login, String password) {
		this.login = login;
		this.password = password;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getLogin() {
		return login;
	}

	public void setLogin(String login) {
		this.login = login;
	}

	@Override
	public String toString() {
		return "CfpSecurity{" +
			"login='" + login + '\'' +
			", password='" + password + '\'' +
			'}';
	}

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (!(o instanceof CfpSecurity)) return false;

        CfpSecurity that = (CfpSecurity) o;

        if (login != null ? !login.equals(that.login) : that.login != null) return false;
        if (password != null ? !password.equals(that.password) : that.password != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = login != null ? login.hashCode() : 0;
        result = 31 * result + (password != null ? password.hashCode() : 0);
        return result;
    }
}
